package com.hzdy.master.entity.data;

import com.hzdy.master.entity.Detail;
import com.hzdy.master.entity.reange.ReangeType;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.*;
import java.io.Serializable;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: LALA
 * Date: 2019-03-11
 * Time: 9:36
 */
@Getter
@Setter
@Entity
@Table(name = "data_element")
public class DataElement extends Detail implements Serializable {
    //标识符
    private String identifier;

    //数据元数据类型
    private String dataType;

    //表达方式
    private String expression;

    //标准值域类型
    @OneToOne
    private ReangeType reangeType;

    @ManyToOne(
            cascade = CascadeType.REFRESH,
            fetch=FetchType.LAZY
    )
    private DataElementType dataElementType;
}
